<p>
  <h1><%=h @company.name %></h1>
</p>
<p>
	<%= link_to 'Back', companies_path %> | <%= link_to 'New store', new_store_path %>
</p>
<h2>Stores</h2>
<table>
  <tr>
    <th>Code</th>
    <th>Location</th>
    <th>Zipcode</th>
	<th>Action</th>
  </tr>

  <% for store in @company.stores %>
    <tr class="<%= cycle('even', 'odd') %>">
      <td><%=h store.code %></td>
      <td><%=h store.location %></td>
      <td><%=h store.zipcode %></td>
      <td>
      	<%= link_to image_tag("edit.gif"), edit_store_path(store) %>
		<%= link_to image_tag("delete.gif"), store, :confirm => 'Are you sure?', :method => :delete %>
	</td>
    </tr>
  <% end %>
</table>